<?php  

ini_set('display_errors', 1);
error_reporting(E_ALL & ~E_NOTICE);
date_default_timezone_set('Asia/Shanghai');
header("Content-Type:text/html; charset=utf-8");






?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档</title>
<style>
body{
	
	font-size:14px;}
</style>
</head>

<body>
<?php
if(!empty($hkey)){//HASH
	echo "类型：HASH　key:".$key."　hkey：".$hkey."<br>";
	$r = $redis->hget($key, $hkey);
}else if($i >= 0){//STRING
	echo "类型：List　key:".$key."　i：".$i."<br>";
	$r = $redis->lget($key, $i);
}else{
	echo "类型：String，key:".$key."<br>";
	$r = $redis->get($key);
}


echo "<br>";
echo indent($r);

?>
</body>
</html>